﻿using FluentAssertions;
using Microsoft.VisualStudio.TestTools.UnitTesting;
using MyCompany.WebCrawler.Tasks;
using MyCompany.WebCrawler.Tasks.Tasks;

namespace MyCompany.WebCrawler.Test.Domain.TasksFactoryTests.Given_TaskFactory
{
    [TestClass]
    public class When_CreateDifferentTasks : Context
    {
        private readonly TasksFactory factory = new TasksFactory(null, null, null);
        
        [TestMethod]
        public void Then_ShowNewLinksTaskCreated()
        {
            var task = factory.CreateShowNewLinkTask();

            task.Should().BeOfType<ShowNewLinksTask>();
        }

        [TestMethod]
        public void Then_GetLinksFromTaskCreated()
        {
            var task = factory.CreateGetLinks("http://googole.com");

            task.Should().BeOfType<GetLinksFromTask>();
        }
    }
}